From: Jim Blandy Date: Thu, 10 Jun 1993 05:21:01 +0000 (+0000) Subject: * fileio.c (Frename_file): Pass all arguments to the file name handler. X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~95462 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=a5a44b91052c1b841c8aeccf4c563242072a3ad8;p=emacs.git * fileio.c (Frename_file): Pass all arguments to the file name handler. * eval.c (call4): New function. --- diff --git a/src/eval.c b/src/eval.c index 2812c79e0d3..476f663f09f 100644 --- a/src/eval.c +++ b/src/eval.c @@ -1803,6 +1803,30 @@ call3 (fn, arg, arg1, arg2) #endif /* not NO_ARG_ARRAY */ } +/* Call function fn with arguments arg, arg1, arg2, arg3 */ +/* ARGSUSED */ +Lisp_Object +call4 (fn, arg, arg1, arg2, arg3) + Lisp_Object fn, arg, arg1, arg2, arg3; +{ + struct gcpro gcpro1; +#ifdef NO_ARG_ARRAY + Lisp_Object args[5]; + args[0] = fn; + args[1] = arg; + args[2] = arg1; + args[3] = arg2; + args[4] = arg3; + GCPRO1 (args[0]); + gcpro1.nvars = 5; + RETURN_UNGCPRO (Ffuncall (5, args)); +#else /* not NO_ARG_ARRAY */ + GCPRO1 (fn); + gcpro1.nvars = 5; + RETURN_UNGCPRO (Ffuncall (5, &fn)); +#endif /* not NO_ARG_ARRAY */ +} + DEFUN ("funcall", Ffuncall, Sfuncall, 1, MANY, 0, "Call first argument as a function, passing remaining arguments to it.\n\ Thus, (funcall 'cons 'x 'y) returns (x . y).") diff --git a/src/fileio.c b/src/fileio.c index bf2391c6894..d7805c5d582 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -1748,7 +1748,8 @@ This is what happens in interactive use with M-x.") call the corresponding file handler. */ handler = Ffind_file_name_handler (filename); if (!NILP (handler)) - return call3 (handler, Qrename_file, filename, newname); + return call4 (handler, Qrename_file, + filename, newname, ok_if_already_exists); if (NILP (ok_if_already_exists) || XTYPE (ok_if_already_exists) == Lisp_Int)